package com.company.project.email.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.company.project.email.entity.EmailEntity;
import com.company.project.sys.entity.SysLog;

import javax.mail.MessagingException;
import java.io.UnsupportedEncodingException;

/**
 * 发送邮件接口
 * @author ZYF
 * @date 2021/8/24 16:11
 */
public interface EmailService extends IService<EmailEntity> {

    /**
     * 发送邮件(普通文件)
     *
     * @param emailEntity
     * @throws MessagingException
     * @throws UnsupportedEncodingException
     */
    void sendMail(EmailEntity emailEntity) throws MessagingException, UnsupportedEncodingException;

    /**
     * 发送附件Mail
     * @param emailEntity
     * @throws MessagingException
     */
    void sendAttachmentMail(EmailEntity emailEntity) throws MessagingException;

    /**
     * 发送html文件
     * @param emailEntity
     * @throws MessagingException
     */
    void sendSimpleMailHtml(EmailEntity emailEntity) throws MessagingException;
}
